FIG. 1 is a simplified block diagram of a Prior Art DVD player 100. For the purposes of illustration, a typical DVD playback system 100 is illustrated as being comprised of a streaming layer 120 and a presentation layer or engine 140. Although illustrated here as blocks in a block diagram, streaming layer 120 and presentation engine 140 may be provided in whole or in part as software and/or firmware elements in a DVD playback device 100.
Streaming layer 120 may encompass the operations of data retrieval from data source (DVD) 110 and disc access navigation 130. Streaming layer 120 receives a stream of video data in Motion Picture Expert Group (MPEG) format (e.g., MPEG-2) or the like, from DVD 110. Disc access Navigator 130 may receive input signals from a user via remote control 155 or the like to control which segments of DVD 110 are played, or to activate special features from DVD 110, or other DVD operations (pause, reverse, fast-forward, or the like). Thus, streaming layer 120 is also responsible for handling user operations (since user operations are typically handled at the navigator level).
Presentation engine 140 encompasses decode and render operations to decode DVD data from data source 110 and present an image on display 150 and audio output on speakers 160A and 160B. Since data from DVD 110 may be in MPEG-2 or other compressed formats, presentation engine 140 is used to decode this data and convert it into audio and video outputs which are compatible with display 150 and speakers 160A and 160B. Presentation engine 140 also synchronizes the audio and video portions such that the output is properly synchronized. Presentation engine may output signals in a number of formats including National Television Standards Committee (NTSC), Phase Alternating Lines (PAL), Systeme Electronique Couleur Avec Memoire (SECAM) or High Definition Television (HDTV) video, in interlaced or sequential scan formats. Audio output may be embedded into these video signals and/or may be output as a separate signal in digital form, or as analog outputs in a number of formats including various surround sound formats known in the art. Two speakers 160A and 160B are shown here for purposes of illustration. Other numbers of speakers may be used, as in a home theater installation, or a speaker in the display (e.g., television) 150 may be used for audio output.
When streaming data from DVD 110 through a DVD player 100 to a television or other output display 150, a time discontinuity may exist between the image being displayed on display 150 and the data being streamed from the disc 110. In other words, in a typical system, a time lag of processing data between the streaming layer 120 and the presentation engine 140.
The time lag of processing data between the streaming layer 120 and presentation engine 140 arises at least in part from a need to buffer as much data as possible in buffer 140A to improve performance of DVD player 100. Buffering data in buffer 140A allows for smooth playback even if certain disk read operations take a longer time than usual because of scratches or bad sectors. Reads from the disk could also take a longer time whenever the playback is forced to seek to different positions on the disk, since the process of seeking for data on an optical media drive is time consuming. Without buffer 140A, the output on display 150 may be interrupted if the processing of data at streaming layer 120 falls behind the generation of data at presentation engine 140 because of bad sector reads. As MPEG-2 and other compressed data is compressed in a non-uniform fashion (depending upon content), a buffer 140A is necessary to ensure a smooth continuous data stream to presentation engine 140.
The time lag of processing data between streaming layer 120 and presentation engine 140 is also a result of a possible lag between temporally co-located audio and video access units in the data stream. For example, if an audio frame and a video frame, which are expected to be rendered simultaneously are separated by one second in the multiplexed stream, buffer 140A would have to be large enough to accommodate at-least one second of the multiplexed stream at the highest possible bit-rate. The lag would be even more for lower bit-rates. The delay may run from 1 to as many as 10 seconds between streaming layer 120 and presentation engine 140.
The time lag of processing data between streaming layer 120 and presentation engine 140 necessitates special synchronization mechanisms to ensure that user actions are effected on what is being currently rendered rather than what is being currently streamed.
For example, if the user wants to activate certain buttons or other features that appear for only a few seconds in the stream, or change every few frames, the streaming layer has to be able to know the exact frame that was being rendered when the user interaction happened.
An example of such a button is what is commonly known as an “Easter Egg”. These are “hidden” features placed in a DVD which, when activated by users “in the know”, can show special DVD features or other surprises. If the user clicks on the “Easter Egg” button (which may appear as an object on the screen), a hidden scene, feature, or other item may be activated. Other types of buttons or devices, which may be activated within a DVD, exist. The Easter Egg is used here only as an example where synchronization between the streaming layer and presentation layer is important.
If, for example, an Easter Egg is displayed in the video for only a few seconds, and the user tries to click on the button using remote control 155, the intended operation may not work if the streaming layer/presentation engine synchronization is not frame-accurate. An operation of presentation engine 140 is displayed on the screen, whereas user controls are handled by disc access navigator 130, which may not be in sync with presentation engine 140, due to the presence of buffer 140A as well as other delays. Thus, the user may try to activate an operation using remote control 155 in response to an Easter Egg appearing on display 150, but streaming layer 120 has already passed that point in the data stream, and does not recognize the command from remote control 155. At the streaming layer, the Easter Egg may have appeared as many as 1 to 10 previous seconds and is no longer active.
One solution to this problem would be to buffer less data in buffer 140A, and thus have only one to two seconds of discontinuity between the displayed image and the streaming data. However, this “solution” would result in poor performance, as if the DVD is damaged or scratched and needs to be read more than once in any given portion, the data flow may be interrupted, resulting in a jerky or stopped image on display 150. Moreover, if the Easter Egg or other button appears only for a second or two in a scene, even minimal buffering may be insufficient, as the streaming layer will have passed the point in the video where the Easter Egg appears by the time the user can activate remote control 155.
In addition, reducing buffering may make implementing advanced features such as slow reverse, more difficult, if not impossible. Furthermore, a smaller buffer does not always guarantee a smaller time lag since typical DVD-Video encoding (MPEG-2) is Variable Bit-rate. With the same buffer size, one might have a one second lag at one point in the stream, and might have a four second lag at another point. In general, more buffering is better, so such a “solution” is not a viable option for a DVD player.